package com.salon.modules.sys.controller;

import com.salon.common.http.response.PageResult;
import com.salon.modules.sys.entity.SysLogEntity;
import com.salon.modules.sys.service.ISysLogService;
import java.util.Map;
import javax.annotation.Resource;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import springfox.documentation.annotations.ApiIgnore;

/**
 * 系统日志
 */
@RestController
@RequestMapping("/sys/log")
@Api(tags="日志管理")
public class SysLogController {

    @Resource
    private ISysLogService sysLogService;

    @GetMapping("/list")
    @ApiOperation("分页")
    @RequiresPermissions("sys:log:select")
    public PageResult<SysLogEntity> list(@ApiIgnore @RequestParam Map<String, Object> params) {
        return sysLogService.listByPage(params);
    }

}
